let t = require;
let  e = module
let  o =  e.exports;
 o.default =  e.exports;

                'use strict';
                console.log("start"),
                    Object.defineProperty(o, '__esModule', {
                        value: !0
                    });
                var n = t('StrUtils'),
                    i = t('Logger'),
                    r = t('MathUtils'),
                    a = (function() {
                        function t() {}
                        return (
                            (t.GET = function(t, e, o, r) {
                                void 0 === r && (r = null);
                                var a = new XMLHttpRequest();
                                (a.onreadystatechange = function() {
                                    if (4 == a.readyState)
                                        if (a.status >= 200 && a.status < 400) {
                                            var t = a.responseText;
                                            if (t) {
                                                var e = JSON.parse(t);
                                                o.call(r, e);
                                            } else
                                                i.Logger.log('返回数据不存在'),
                                                o.call(r, {
                                                    errCode: 0,
                                                    errMsg: '返回数据不存在'
                                                });
                                        } else
                                            i.Logger.log('请求失败-' + a.status),
                                            o.call(r, {
                                                errCode: 0,
                                                errMsg: '网络异常，请稍后再试'
                                            });
                                }),
                                a.open('GET', t + '?' + n.default.formatHttpParams(e), !0),
                                    a.send();
                            }),
                            (t.POST = function(t, e, o, r) {
                                void 0 === r && (r = null);
                                var a = new XMLHttpRequest();
                                (a.onreadystatechange = function() {
                                    if (4 == a.readyState)
                                        if (a.status >= 200 && a.status < 400) {
                                            var t = a.responseText;
                                            if (t) {
                                                var e = JSON.parse(t);
                                                o && o.call(r, e);
                                            } else o && o.call(r, null);
                                        } else
                                            i.Logger.log('请求失败-' + a.status),
                                            o &&
                                            o.call(r, {
                                                errCode: 0,
                                                errMsg: '网络异常，请稍后再试'
                                            });
                                }),
                                a.open('POST', t, !0),
                                    a.setRequestHeader(
                                        'Content-Type',
                                        'application/x-www-form-urlencoded'
                                    ),
                                    a.send(n.default.formatHttpParams(e));
                            }),
                            (t.encodePost = function(e, o, a, s) {
                                void 0 === s && (s = null);
                                var c = new XMLHttpRequest();
                                c.onreadystatechange = function() {
                                    if (4 == c.readyState)
                                        if (c.status >= 200 && c.status < 400) {
                                            var e = c.responseText;
                                            if (e) {
                                                var o = JSON.parse(e),
                                                    n = t.decode(o.t, o.v);
                                                a.call(s, n);
                                            } else i.Logger.log('返回数据不存在'), a.call(s, null);
                                        } else
                                            i.Logger.log('请求失败-' + c.status),
                                            a.call(s, {
                                                errCode: 0,
                                                errMsg: '网络异常，请稍后再试'
                                            });
                                };
                                var l = r.default.randomInt(1e7, 99999999),
                                    u = {
                                        t: l,
                                        v: t.encode(l, o)
                                    };
                                c.open('POST', e, !0),
                                    c.setRequestHeader(
                                        'Content-Type',
                                        'application/x-www-form-urlencoded'
                                    ),
                                    c.send(n.default.formatHttpParams(u));
                            }),
                            (t.encrypt = function(t, e) {
                                for (
                                    var o,
                                        n = e.length,
                                        i = (t ^ n) % 255,
                                        r = ((n & i) + (t ^ i)) % 255,
                                        a = [],
                                        s = 0; s < n; s++
                                ) {
                                    (i -= ((r * n) ^ t) % 255),
                                    (t -= r),
                                    (o = 255 & ((o = e[s]) ^ (r = i % 255))),
                                    a.push(o);
                                }
                                return a;
                            }),
                            (t.encode = function(e, o) {
                                var i = JSON.stringify(o),
                                    r = t.encrypt(e, n.default.stringToByte(i));
                                return n.default.parseByte2HexStr(r);
                            }),
                            (t.decode = function(e, o) {
                                var i = t.encrypt(e, n.default.parseHexStr2Byte(o)),
                                    r = n.default.byteToString(i);
                                return JSON.parse(r);
                            }),
                            t
                        );
                    })();
                (o.default = a), console.log("end");
            module.exports =  e.exports;